/*
* $Id: MainWin.h 2 2009-12-23 13:58:02Z volok-aleksej@yandex.ru $
*
* Copyright 2008 by Volokitin Alexey
* All rights reserved
*
*/
#ifndef _MAIN_WIN_H_
#define _MAIN_WIN_H_

#include "PictureButton.h"
#include "Wnd.h"

class CMainWin : public CFrameWnd, public CWndImpl
{
	CFont* m_pFont;
	bool m_bDownMouseButton;
	CPoint m_pointMouse;
	CBitmap* m_pBitmapLogo;
	CBitmap* m_pBitmapHeader;
	CPictureButton m_CloseButton;
	CPictureButton m_FoldButton;
	std::vector<IVisualComponent*> m_aComponentButtons;
protected:
	void DrawBitmap(CBitmap* pBitmap);
	virtual BOOL OnCommand(WPARAM wParam, LPARAM lParam);
protected:
	DECLARE_MESSAGE_MAP();
	afx_msg void OnPaint();
	afx_msg void OnTimer(UINT_PTR);
	afx_msg void OnLButtonDown(UINT, CPoint);
	afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct);
	afx_msg void OnDestroy();
public:
	CMainWin(const std::vector<IVisualComponent*>& aVisualComponents);
	virtual ~CMainWin();
	virtual void Free();
};

#endif /*_MAIN_WIN_H_*/